<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title><%= htmlWebpackPlugin.options.config.BUILD_TITLE %></title>
    <link rel="shortcut icon" href="/static/favicon.ico" type="image/x-icon">
  </head>
  <body>
    <div id="app"></div>
    <!-- built files will be auto injected -->
    <script type="text/javascript">
        window.Site = {
            url: <%= htmlWebpackPlugin.options.config.API_URL %>,
            version: <%= htmlWebpackPlugin.options.config.API_VERSION %>,
            login: <%= htmlWebpackPlugin.options.config.API_LOGIN %>,
            agent: <%= htmlWebpackPlugin.options.config.AGENT_URL %>,
            authscheme: <%= htmlWebpackPlugin.options.config.AUTH_SCHEME %> || 'internal',
            authCenter: <%= htmlWebpackPlugin.options.config.AUTH_CENTER %>,
            buildVersion: '<%= htmlWebpackPlugin.options.config.BUILD_VERSION %>',
            fullTextSearch: <%= htmlWebpackPlugin.options.config.FULL_TEXT_SEARCH %> || 'off',
        }
        window.User = {
            admin: <%= htmlWebpackPlugin.options.config.USER_ROLE %>,
            name: <%= htmlWebpackPlugin.options.config.USER_NAME %>
        }
        window.Supplier = {
            account: '0'
        }
        window.API_HOST = Site.buildVersion.indexOf('dev') !== -1 ? Site.url : (window.location.origin + '/')
        window.API_PREFIX = API_HOST + 'api/' + Site.version
    </script>
  </body>
</html>
